<!DOCTYPE html>

<html>
    <head>
        <meta charset="utf-8">
        <title>好运</title>
        <style>
            [title]{
                color: blue;
            }
            [title=baidu]{
                border: 5px solid green;
            }
        </style>
    </head>
    <body>
        <h2>will apply to</h2>
        <h1 title="Hello world">HelloWorld</h1>
        <a title="baidu" href="https://www.baidu.com" target="_blank">百度一下</a>
        <hr>
        <h2>will not apply to</h2>
        <p>hello</p>
    </body>
</html>